Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Refactor spawner to be able to reuse code for ros2controlcli (backport #1661) #1696

Open
wants to merge 3 commits into
base: iron
Choose a base branch
from

Conversation

mergify[bot]
Copy link
Contributor

@mergify mergify bot commented Aug 19, 2024

@christophfroehlich has mentioned that ros2 control CLI is missing the functionality to load controllers with the parameter files as we have now with the spawner. upon reviewing the code, the code would need some refactoring to reduce some duplication of code in both places and to be able also to load controllers with namespaced controller manager

This PR would be the first part of refactoring that can go along with #1562, once both the PRs are done, the ros2 control CLI can be modified to add the parameter parsing from the file and proper usage with namespacing.


This is an automatic backport of pull request #1661 done by Mergify.

(cherry picked from commit 0631e3e)

# Conflicts:
#	controller_manager/controller_manager/spawner.py
#	controller_manager/test/test_spawner_unspawner.cpp
Copy link
Contributor Author

mergify bot commented Aug 19, 2024

Cherry-pick of 0631e3e has failed:

On branch mergify/bp/iron/pr-1661
Your branch is up to date with 'origin/iron'.

You are currently cherry-picking commit 0631e3e.
  (fix conflicts and run "git cherry-pick --continue")
  (use "git cherry-pick --skip" to skip this patch)
  (use "git cherry-pick --abort" to cancel the cherry-pick operation)

Changes to be committed:
	modified:   controller_manager/controller_manager/__init__.py
	modified:   controller_manager/controller_manager/controller_manager_services.py
	modified:   controller_manager/controller_manager/hardware_spawner.py
	modified:   ros2controlcli/ros2controlcli/verb/list_controllers.py
	modified:   ros2controlcli/ros2controlcli/verb/list_hardware_components.py
	modified:   ros2controlcli/ros2controlcli/verb/list_hardware_interfaces.py

Unmerged paths:
  (use "git add <file>..." to mark resolution)
	both modified:   controller_manager/controller_manager/spawner.py
	both modified:   controller_manager/test/test_spawner_unspawner.cpp

To fix up this pull request, you can check it out locally. See documentation: https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/reviewing-changes-in-pull-requests/checking-out-pull-requests-locally

@mergify mergify bot added the conflicts label Aug 19, 2024
saikishor and others added 2 commits August 31, 2024 23:06
* Fix conflicts

* added controller_type parameter setting to the spawner
Copy link

codecov bot commented Aug 31, 2024

Codecov Report

Attention: Patch coverage is 74.07407% with 14 lines in your changes missing coverage. Please review.

Project coverage is 62.12%. Comparing base (62a609c) to head (be351a8).

Files with missing lines Patch % Lines
.../controller_manager/controller_manager_services.py 76.47% 7 Missing and 5 partials ⚠️
controller_manager/controller_manager/spawner.py 33.33% 0 Missing and 2 partials ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             iron    #1696      +/-   ##
==========================================
- Coverage   62.17%   62.12%   -0.06%     
==========================================
  Files         109      109              
  Lines       12206    12205       -1     
  Branches     8552     8556       +4     
==========================================
- Hits         7589     7582       -7     
- Misses        866      870       +4     
- Partials     3751     3753       +2     
Flag Coverage Δ
unittests 62.12% <74.07%> (-0.06%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
controller_manager/controller_manager/__init__.py 100.00% <ø> (ø)
...ler_manager/controller_manager/hardware_spawner.py 0.00% <ø> (ø)
controller_manager/controller_manager/spawner.py 70.24% <33.33%> (-4.60%) ⬇️
.../controller_manager/controller_manager_services.py 70.68% <76.47%> (+4.53%) ⬆️

... and 3 files with indirect coverage changes

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants